package com.du.stutestsys.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.du.stutestsys.util.PageUtil;
import org.apache.ibatis.annotations.Mapper;
import com.du.stutestsys.entity.SysUser;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Mapper
public interface SysUserMapper extends BaseMapper<SysUser> {
    SysUser Login(@Param("sysUser") SysUser sysUser);

    Integer addUser(@Param("sysUser") SysUser sysUser);

    Integer deleteAdmin(@Param("sysUserList") List<SysUser> sysUserList);

    Integer updateAdmin(@Param("sysUser")SysUser sysUser);

    List<SysUser> selectUser(SysUser sysUser, @Param("pageUtil") PageUtil pageUtil);

    Integer updatePrivilegeAdmin(@Param("sysUserList") List<SysUser> sysUserList);


    Integer addStu(@Param("user_id") Long user_id, @Param("class_id") Long class_id);

    Integer deleteStu(@Param("stuIds") List<Long> stuIds);

    Integer updateTeaSub(SysUser sysUser);

    Long selectSubId(@Param("subjectid") Long subjectid);

    List<SysUser> selectStu(SysUser sysUser,@Param("pageUtil") PageUtil pageUtil);
}
